package com.atguigu.spi;

import org.apache.dubbo.common.URL;

public class CarWrapper implements Car{
    private Car car;
    public CarWrapper(Car car) {
        this.car = car;
    }
    @Override
    public String carType() {
        System.out.println("before-OrderWrapper对way()的增强");
        String way = car.carType();
        System.out.println("after-OrderWrapper对way()的增强");
        return way;
    }

    @Override
    public String carName(URL url) {
        System.out.println("before-OrderWrapper对pay()的增强");
        String pay = car.carName(url);
        System.out.println("after-OrderWrapper对pay()的增强");
        return pay;
    }
}
